﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using IsmsExplorer.Infrastructure.RepositoryFramework;

namespace IsmsExplorer.Model.Documents {
    public interface IIsmsDocumentLinkRepository : IRepository<IsmsDocumentLink> {
        IList<IsmsDocumentLink> GetDocumentsForIso27001Control(int projectID, int controlID);

        /// <summary>
        /// Each document is uniquely identified by a GUID but also the document URL must be unique
        /// within the database table for a particular project. A specific document cannot have two 
        /// different representations unless it is in a different repository.
        /// </summary>
        /// <param name="projectID"></param>
        /// <param name="documentUrl"></param>
        /// <param name="repositoryTypeID"></param>
        /// <returns></returns>
        IsmsDocumentLink FindByUrlInRepository(int projectID, string documentUrl, int repositoryTypeID);

        IList<IsmsDocumentLink> GetDocumentsByTypeID(int projectID, int documentTypeID);

        IList<IsmsDocumentLink> GetAllIsmsDocumentLinksForProject(int projectID);
    }
}
